<%@ page language="java" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="shiro" uri="http://shiro.apache.org/tags"%>
<script>
	$(document).ready(function() {
		// use this to reset a single form 只是ID为form的表单执行reset()方法
		$("#submit").click(function() {
			$("#form")[0].submit();
		});
	});
</script>

<div id="leftbar" class="span2">
	<h3>主菜单</h3>
	<a id="account-tab" href="${ctx}/admin/user">帐号管理</a>
	<c:if test="${menus == null }">
	<form id="form" action="${ctx}/menu">
	</form>
	</c:if>
	<c:forEach items="${menus}" var="menu">
		<div class="submenu">
			<a id="${menu.menucode}" href="${ctx}/${menu.menuurl}">${menu.menuname}</a>
		</div>
	</c:forEach>
</div>